06. Solution: Creating and Saving NumPy ndarrays
Solution: ABC's
import numpy as np
# create numpy array of letters a-j
letter_array = np.array(['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j'])
print("Array:", letter_array)
# get dtype of array
print("Dtype:", letter_array.dtype)
# get shape of array
print("Shape:", letter_array.shape)
# get size of array
print("Size:", letter_array.size)
Output:
Array: ['a' 'b' 'c' 'd' 'e' 'f' 'g' 'h' 'i' 'j']
Dtype: <U1
Shape: (10,)
Size: 10